package com.hc.model.code03.test4;

/**
 * @version v1.0
 * @ClassName: Bacon
 * @Description: 培根类（具体装饰者类）
 * @Author: HC
 */
public class Bacon extends Garnish{

    public Bacon(FastFood fastFood) {
        super(fastFood, 2, "培根");
    }


    @Override
    public float cost() {
        return getPrice() + getFastFood().cost();
    }

    @Override
    public String getDesc() {
        return super.getDesc() + super.getFastFood().getDesc();
    }
}
